package com.weiyuwqj.server.service.sys.impl;

import com.github.pagehelper.PageHelper;
import com.weiyuwqj.api.common.PageList;
import com.weiyuwqj.api.common.Paginator;
import com.weiyuwqj.api.model.SysFee;
import com.weiyuwqj.api.model.vo.SysFeeVo;
import com.weiyuwqj.api.service.SysFeeService;
import com.weiyuwqj.server.mapper.SysFeeMapper;
import com.weiyuwqj.server.service.base.BaseServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

/**
 * Created by huzj on 2017/4/25.
 */
@Service ("sysFeeService")
public class SysFeeServiceImpl extends BaseServiceImpl<SysFee> implements SysFeeService{
    @Autowired
    private SysFeeMapper sysFeeMapper;
    @Override
    public PageList getList(Paginator p, Map<String, Object> map) {
        PageHelper.startPage(p.getPageNum(),p.getPageSize());
        List<SysFeeVo> list = sysFeeMapper.getList(map);
        return new PageList(list);
    }

    @Override
    public Map statCount(Map<String, Object> map) {
        return sysFeeMapper.statCount(map);
    }

    @Override
    public List<SysFeeVo> getList(Map<String, Object> map) {
        return sysFeeMapper.getList(map);
    }
}
